﻿IF EXISTS (SELECT * FROM sysobjects WHERE type = 'P' AND name = 'GetBienByID')
	BEGIN
		DROP  Procedure  GetBienByID
	END

GO

CREATE Procedure GetBienByID

	(
		@id int
		
	)


AS
begin
SELECT
	[bien].[Descripcion] AS 'Descripcion',
	[bien].[Estado] AS 'Estado',
	[bien].[IdBien] AS 'IdBien',
	[bien].[IdUnidadMedida] AS 'IdUnidadMedida',
	[bien].[Nombre] AS 'Nombre',
	[bien].[Precio] AS 'Precio',
	[bien].[StockActual] AS 'StockActual',
	[bien].[StockMinimo] AS 'StockMinimo'
FROM [dbo].[Bien] [bien] 
where [bien].[IdBien]= @id
end


GO


GRANT EXEC ON GetBienByID TO PUBLIC

GO


